< previous page page_629 next page >

Page 629
Directly Transmitted Light
Transparent surfaces add a little more complication to ray tracing than reflective ones. Transparent surfaces add not only to the global component a pixel's color but also to the local component.
The local contribution comes from light passing from the light source directly to an object and then through the object to the point. Figure 17.26 shows this situation. Usually, the viewpoint and light source are in the same substance. They both lie outside any objects in the scene's ''air." This term is important, however, for rays that you trace recursively through transparent objects. Rays that originate inside transparent objects see this type of local contribution.
The vector L runs between the light source and the point of intersection. V runs from the intersection to the viewpoint. The vector T is a vector in the direction in which the light is refracted according to Snell's law.
Just as not all the specularly reflected light travels along the path of reflection, not all the refracted light travels along the vector T. You can model the light that actually reaches the viewpoint in a manner similar to the way you model specular reflection. You can set the amount of refracted light reaching the viewpoint to be some constant times the cosine of the angle f raised to some power. You can select the constant and power to give you the sort of characteristics you want your object to have. If the vectors V and T are unit vectors, then Cos(f) = V T, so you can let the direct reflected component for the light be:
e10a6a0a59f035e870d90cca05b85fce.gif
Ii * kt * (V  T)Nt
0629-01.gif
Figure 17.26
Not all transmitted light follows
the direction of refraction.

 
< previous page page_629 next page >